package com.chuqiyun.authorization.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;

/**
 * 订单(Order)表实体类
 *
 * @author mryunqi
 * @since 2023-04-19 17:07:10
 */
@EqualsAndHashCode(callSuper = true)
@TableName(value = "Order")
@Data
public class Order extends Model<Order> {
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    
    private String orderId;
    //账单id
    private String billId;
    //用户唯一ID
    private String userUuid;
    //商品id
    private String commodityId;
    //支付周期范围
    private String commodityPriceCycle;
    //订单名
    private String name;
    //订单金额
    private String orderPrice;
    //优惠券
    private String coupon;
    //兑换码
    private String exchangeCode;
    //支付状态（0=未支付，1=已支付，2=已取消）
    private Integer state;
    //下单时间
    private Long orderTime;



    /**
     * 获取主键值
     *
     * @return 主键值
     */
    @Override
    public Serializable pkVal() {
        return this.id;
    }
    }

